package org.goyo.main.domain.dao.sale.impl;

import java.util.List;

import org.goyo.common.exception.DBException;
import org.goyo.main.domain.dao.BaseDAO;
import org.goyo.main.domain.dao.sale.IReceiptDao;
import org.goyo.main.domain.entity.sale.Receipt;
import org.springframework.stereotype.Repository;

@Repository
public class ReceiptDaoImpl extends BaseDAO implements IReceiptDao{
	
	@Override
	public List<Receipt> findByParentId(String parentId) throws DBException {
		String hql = "from Receipt where parentId=?";
		return this.findObjects(hql, null, new Object[]{parentId});
	}
}
